We start with a dim factor of 0, so the syncEnabled() call in the
constructor will always disable the effect. Just create the effect
disabled and save the method call.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/654
var WindowDimmer = class {
constructor(actor) {
- this._brightnessEffect = new Clutter.BrightnessContrastEffect();
+ this._brightnessEffect = new Clutter.BrightnessContrastEffect({
+ enabled: false
+ });
actor.add_effect(this._brightnessEffect);
this.actor = actor;
this._enabled = true;
this._dimFactor = 0.0;
- this._syncEnabled();
}
_syncEnabled() {